package com.hxd.otc.api;


import com.hxd.otc.base.BaseBean;
import com.hxd.otc.module.wallet.bean.LoanRecoderBean;
import com.hxd.otc.module.wallet.bean.LoanRuleBean;

import java.util.List;

import io.reactivex.Observable;
import okhttp3.RequestBody;
import retrofit2.http.Body;
import retrofit2.http.GET;
import retrofit2.http.POST;
import retrofit2.http.Query;

/**
 * 包  名 :  com.hxd.wcb.client.api
 * 类  名 :  IloanApi
 * 作  者 :  zjl
 * 时  间 :  2018/7/23 11:01
 * 描  述 :  ${TODO}
 */
public interface ILoanApi {

    //查询最近一笔待还款记录信息
    @GET("loan/lastDueDateLoanInfo")
    Observable<BaseBean<LoanRecoderBean>> getLastLoaninfo();

    //查询贷款记录
    @GET("loan/loanInfo")
    Observable<BaseBean<List<LoanRecoderBean>>> getLoanRecord(@Query("current") int pageNo, @Query("size") int pageSize);  //查询贷款记录

    //贷款规则
    @GET("loan/loanRuleInfo")
    Observable<BaseBean<List<LoanRuleBean>>> getLoanRuleInfo();

    //添加贷款信息
    @POST("loan/saveLoanInfo")
    Observable<BaseBean<LoanRecoderBean>> saveLoanInfo(@Body RequestBody body);
}
